package java_DesignPattern.StructuralPattern.DecoraterPattern;

/**
 * 蔬菜类
 */
public class ShuCai extends Decorater {

    public ShuCai(FastFood fastFood) {
        super(fastFood, 2F, "加一个蔬菜");
    }

    @Override
    public float calcPrice() {
        return getPrice() + getFastFood().calcPrice();
    }
}
